package com.example.demo.project.domain;

import org.springframework.context.annotation.ComponentScan;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * Created by Administrator on 2018-2-7.
 */
public interface StudentRepository extends JpaRepository<Student,Integer> {
    /**
     * 扩展,按年龄查询
     * @param age
     * @return
     */
    public List<Student> findByAge(Integer age);
    public List<Student> findByName(String name);
}
